package org.monkey4j.suppliers;

import java.util.Collection;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

import com.google.common.base.Supplier;

import static java.util.Collections.emptyList;

/**
 * {@link Supplier} implementation representing some kind of a null object.
 * 
 * @author hillger.t
 */
public final class EmptySupplier implements Supplier<Collection<Object>> {
	private static final Logger LOG = LoggerFactory.getLogger(EmptySupplier.class);
	
	public Collection<Object> get() {
		if (LOG.isWarnEnabled()) LOG.warn("No valid supplier found - so using EmptySupplier class.");
		return emptyList();
	}
}
